#pragma once

#include <uapi/linux/const.h>

/* @a is a power of 2 value */
#define ALIGN(x, a) __ALIGN_KERNEL((x), (a))
#define ALIGN_DOWN(x, a) __ALIGN_KERNEL((x) - ((a) - 1), (a))

#define IS_ALIGNED(x, a) (((x) & ((typeof(x))(a) - 1)) == 0)
